package com.ruoyi.business.utils;


import com.ruoyi.business.entity.redis.UserObj;

public class UserObjHolder {
    private static final ThreadLocal<UserObj> tl = new ThreadLocal<>();

    public static void saveUserObj(UserObj userObj){
        tl.set(userObj);
    }

    public static UserObj getUserObj(){
        return tl.get();
    }

    public static void removeUserObj(){
        tl.remove();
    }
}
